package com.carkeeper.search.controller;

/**
 * @author pengjinxiong
 * @version 1.0
 * @date 2020/11/25 9:46
 */


import com.carkeeper.search.service.ServiceSearchService;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

/**
 * 全文搜索控制层
 */
@RestController
@RequestMapping("/search")
public class ServiceSearchController {
    @Autowired
    private ServiceSearchService serviceSearchService;

    @GetMapping
    public Map search(@RequestParam Map searchMap) {
        Map resultMap = serviceSearchService.searchQuery(searchMap);
        return resultMap;
    }
}
